worker.onMessage(function ({workerName, msg}) {
	if (workerName === 'test') {
		console.log(msg)
		worker.postMessage({
			workerName: 'test'
		})		
	}
})
// 在页面中使用的代码
/* const worker = wx.createWorker('src/workers/request.js') // 文件名指定 worker 的入口文件路径，绝对路径
worker.postMessage({
  workerName: 'test'
})
worker.onMessage(({workerName}) => {
	if (workerName === 'test')
	{
		this.title = '1'
	}
}) */